package com.education.wisdom.service.impl;

import com.education.common.utils.Convert;
import com.education.wisdom.mapper.ConcernMapper;
import com.education.wisdom.pojo.Concern;
import com.education.wisdom.service.IConcernService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

/**
 * 关注 服务层实现
 * 
 * @author ruoyi
 * @date 2018-11-20
 */
@Service
public class ConcernServiceImpl implements IConcernService
{
	@Autowired
	private ConcernMapper concernMapper;

	/**
     * 查询关注信息
     * 
     * @param gzConcernid 关注ID
     * @return 关注信息
     */
    @Override
	public Concern selectConcernById(String gzConcernid)
	{
	    return concernMapper.selectConcernById(gzConcernid);
	}
	
	/**
     * 查询关注列表
     * 
     * @param concern 关注信息
     * @return 关注集合
     */
	@Override
	public List<Concern> selectConcernList(Concern concern)
	{
	    return concernMapper.selectConcernList(concern);
	}
	
    /**
     * 新增关注
     * 
     * @param concern 关注信息
     * @return 结果
     */
	@Override
	public int insertConcern(Concern concern)
	{
	    return concernMapper.insertConcern(concern);
	}
	
	/**
     * 修改关注
     * 
     * @param concern 关注信息
     * @return 结果
     */
	@Override
	public int updateConcern(Concern concern)
	{
	    return concernMapper.updateConcern(concern);
	}

	/**
     * 删除关注对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
	@Override
	public int deleteConcernByIds(String ids)
	{
		return concernMapper.deleteConcernByIds(Convert.toStrArray(ids));
	}

	@Override
	public List<Concern> selectConcernsList(Map<String, Object> map) {
		return concernMapper.selectConcernsList(map);
	}

	@Override
	public int updateConcerns(Map<String, Object> map) {
		return concernMapper.updateConcerns(map);
	}

	@Override
	public Concern selectConcerns(Map<String, Object> map) {
		return concernMapper.selectConcerns(map);
	}

	@Override
	public int selectConcernCount(Map<String, Object> map) {
		return concernMapper.selectConcernCount(map);
	}

	@Override
	public Concern selectIsConcerns(Map<String, Object> map) {
		return concernMapper.selectIsConcerns(map);
	}

	@Override
	public int updateConcernes(Map<String, Object> map) {
		return concernMapper.updateConcernes(map);
	}

	@Override
	public int selectMyCount(Map<String, Object> map) {
		return concernMapper.selectMyCount(map);
	}
	
}
